import helpers.Client;

import java.util.List;
import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.CopyOnWriteArrayList;


public class Server extends Thread {

	protected List<Client> m_clients;
	protected Map<Integer,Integer> m_printers;
	protected CopyOnWriteArrayList<TCPClientServer> m_thClients;
	protected int m_zone;
	protected static int ports = 5010;
	public Server()
	{
		m_clients = new CopyOnWriteArrayList<Client>();
		m_thClients = new CopyOnWriteArrayList<TCPClientServer>();
		m_printers = new ConcurrentHashMap<Integer,Integer>(); //Id user , Id imprimanta
		m_zone = 0;
	}
	
	@Override
	public void run()
	{
	}
	
	public void doIt()
	{
		// TCP
				TCPServer serverTCP = new TCPServer(5002, 5003);
				serverTCP.start();
				
				try {
					serverTCP.join();
				} catch (Exception e) {}
	}
	public static void main(String ...args)
	{
		Server server = new Server();
		server.doIt();
		/*// UDP
		UDPServer serverUDP = new UDPServer(50012, 50013);
		serverUDP.start();
		
		try {
			serverUDP.join();
		} catch (Exception e) {}*/
	}
}
